package com.example.erhuo.fragment;

import androidx.lifecycle.ViewModel;

import com.example.erhuo.Good;
import com.example.erhuo.R;
import com.example.erhuo.adapter.GoodAdapter;

public class BuyViewModel extends ViewModel {
    private String testString = "我是你爹";
    public GoodAdapter goodAdapter = null;
    public int type = 0;

    // TODO: Implement the ViewModel

    public String getTestString() {
        return testString;
    }

    public GoodAdapter getGoodAdapter() {
        return goodAdapter;
    }

    public void setGoodAdapter(GoodAdapter goodAdapter) {
        this.goodAdapter = goodAdapter;
    }

    public void addGood(Good good) {
        goodAdapter.addGood(good);
    }

    public void clear(){
        goodAdapter.clear();
    }
}